#define _CRT_SECURE_NO_WARNINGS 1
#include <iostream>
using namespace std;

int main()
{

	int N = 0;
	scanf("%d", &N);

	while (N--)
	{
		int cou = 3;
		int num = 0;
		int sum_1 = 0;
		int sum_2 = 0;

		scanf("%d", &num);

		int flag_1 = num / 1000;
		int flag_2 = num % 1000;
		while (cou--)
		{
			sum_1 += flag_1 % 10;
			flag_1 /= 10;

			sum_2 += flag_2 % 10;
			flag_2 /= 10;
		}

		if (sum_1 == sum_2)
		{
			printf("You are lucky!\n");
		}
		else
		{
			printf("Wish you good luck.\n");
		}

	}

	return 0;
}
